- content_for :wide do
  .form.box
    %h2
      Редактирование профиля
      = current_user.email

    = form_for(resource, :as => resource_name, :url => registration_path(resource_name), :html => { :method => :put, :multipart => true, :onsubmit => "return checkFileSize('user_avatar');" }) do |f|
      = devise_error_messages!

      .left= image_tag f.object.avatar.url(:small)
      .right= f.file_field :avatar

      .clearfix

      .left= f.label :email
      .right= f.email_field :email

      .left= f.label :first_name
      .right= f.text_field :first_name

      .left= f.label :last_name
      .right= f.text_field :last_name

      .left= f.label :password
      .right
        = f.password_field :password, :autocomplete => "off"
        (leave blank if you don't want to change it)

      .left= f.label :password_confirmation
      .right= f.password_field :password_confirmation

      .left= f.label :current_password
      .right
        = f.password_field :current_password
        (we need your current password to confirm your changes)

      .left &nbsp;
      .right.actions
        = f.submit "Обновить", :class => "btn primary small"
        = link_to t('back'), :back, :class => "btn small"

      .clearfix
